<?php 

$titulos = '';
$valors = '';


foreach ($clienteReportes as $clienteReporte) {
        //echo $clienteReporte->getClas()."=".$clienteReporte->getTotal()."<br>"; 

        $titulos.='"'.$clienteReporte->getClas().'('.number_format($clienteReporte->getTotal(),0,',','.').')'.'",'; 
        $valors.=$clienteReporte->getTotal().','; 
        
}
    ?>

<script src="chart/Chart.js"></script>
<div style="margin-top: 5%; margin-left: 10%">
        <canvas id="canvas" height="450" width="600"></canvas>
</div>
	<script>

		var barChartData = {
			labels : [<?php echo $titulos?>],
			datasets : [
				{
					fillColor : "rgba(151,187,205,0.5)",
					strokeColor : "rgba(151,187,205,1)",
					data : [<?php echo $valors?>,2]
				}
			]
			
		}

	var myLine = new Chart(document.getElementById("canvas").getContext("2d")).Bar(barChartData);
	
	</script>